﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using EZCRS.HCMS.Entity;
using EZCRS.HCMS.Data;

namespace EZCRS.HCMS.SqlClient
{
    public class sql_hcrs_airport
    {
        public List<HCRS_Airport> getallitem(int id)
        {
            return ExecSql.GetTableList<HCRS_Airport>("select * from HCRS_Airport where property_id=" + id.ToString());
        }

        public bool delitem(int id)
        {
            if (ExecSql.SqlExecNoquery("delete from HCRS_Airport where airport_id=" + id.ToString()) > 0)
               return true;
           else
               return false;
        }

        public bool insertorupdate(HCRS_Airport _airport)
        {
            return ExecSql.InsertOrUpdateData<HCRS_Airport>(_airport);
        }
    }
}
